package com.csiec.clock.activity.daka;

import androidx.appcompat.app.AppCompatActivity;
import androidx.databinding.DataBindingUtil;
import androidx.lifecycle.ViewModelProvider;
import androidx.recyclerview.widget.LinearLayoutManager;

import android.os.Bundle;
import android.util.Log;

import com.csiec.clock.R;
import com.csiec.clock.adpter.MyClockAdapter;
import com.csiec.clock.bean.MyClock;
import com.csiec.clock.databinding.ActivityMyClockBinding;
import com.csiec.clock.view.model.MyClockViewModel;

import java.util.ArrayList;
import java.util.List;

public class MyClockActivity extends AppCompatActivity {

    private final String TAG = MyClockActivity.class.getSimpleName();
    private ActivityMyClockBinding binding;
    private MyClockViewModel myClockViewModel;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        binding = DataBindingUtil.setContentView(this, R.layout.activity_my_clock);

        //LiveData
        myClockViewModel = new ViewModelProvider(this).get(MyClockViewModel.class);
        binding.setMyClockViewModel(myClockViewModel);
        binding.setLifecycleOwner(this);
        myClockViewModel.init(this, binding);

    }

}